package com.org.service.impl;

import com.org.entity.Userlist;
import com.org.mapper.UserListMapper;
import com.org.service.UserListService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author Rainy-Heights
 * @version 1.0
 * @Date 2023/3/8 11:32
 */
@Service
public class UserListServiceImpl implements UserListService {
    @Resource
    UserListMapper userListMapper;
    @Override
    public List<Userlist> getAllUser() {
      return   userListMapper.getAllUser();
    }

    @Override
    public int insertNewUser(String username, String role, String specials, String hobby) {
        Userlist userlist=new Userlist();
        //逻辑设置：前端获取参数，传入这个service层再实现数据的插入。
        return 0;
    }

    @Override
    public int getActiveNum() {
       return userListMapper.getActiveNum();
    }
}
